﻿<%@ Control Language="VB"  AutoEventWireup="false" CodeFile="SearchDummy.ascx.vb"  Inherits="WebForm_ManageProduct_SearchDummy" %>
    <div style="background-color: #351D26">
<%--     <asp:UpdatePanel ID="up" runat="server">
        <ContentTemplate>--%>
            <asp:MultiView ID="mvEmployee" runat="server" ActiveViewIndex="0">
                <asp:View ID="vwSearch" runat="server">
                    <fieldset id="plSearch" style="border-color: #4E333B" runat="server">
                        <legend class="white2">
                            <asp:Literal ID="Literal1" runat="server" Text="<%$ Resources:plSearch.GroupingText%>" />
                        </legend>
                            <table>
                                <tr>
                                     <td>
                                            <asp:Label ID="lbYear" runat="server" meta:resourcekey="lblYear"></asp:Label>
                                            <asp:DropDownList ID="ddlYear" runat="server"></asp:DropDownList>
                                            <asp:Label ID="lblDivision" runat="server" meta:resourcekey="lblDivision"></asp:Label>
                                            <asp:DropDownList ID="ddlDivision" runat="server" AutoPostBack="True" />
                                            <asp:Label ID="lblSignature" runat="server" meta:resourcekey="lblSignature"></asp:Label>
                                            <asp:DropDownList ID="ddlSignature" runat="server" />
                                    </td>
                                    <td>
                                            <asp:Button ID="btnSearch" runat="server" meta:resourcekey="btnSearch" />
                                    </td>
                               </tr>
                   </table>
                </fieldset>
                <fieldset id="plList" style="border-color: #4E333B" runat="server">
                    <legend class="white2">
                         <asp:Literal ID="Literal2" runat="server" Text="<%$ Resources:plList.GroupingText%>" />
                    </legend>
                        <table id="Table1" width="100%" runat="server">
                            <tr>
                                <td>
                                      <My:MyGridView ID="gv2" runat="server" AllowHoverEffect="True" AllowHoverSelect="True"
                                        TotalRowCount="0" AutoGenerateColumns="False" SkinID="pager" DataKeyNames="SapCode,ProdHierarchy,Description,LocalDescription,MMPP,MaterialType,IsDummy,PAllow,ListP,STD,Active">
                                        <Columns>
                                            <asp:TemplateField HeaderText="NO">
                                                <itemtemplate>
                                                <%#gv2.PageIndex * gv2.PageSize + gv2.Rows.Count + 1%>
                                            </itemtemplate>
                                                <itemstyle horizontalalign="Center" width="60px" />
                                                <headerstyle horizontalalign="Center" width="60px" />
                                            </asp:TemplateField>
                                            <asp:TemplateField meta:resourcekey="gvSapCode" SortExpression="SapCode">
                                                <itemtemplate>
                                                <%#MyObj.GetAreaCode() + Eval("SapCode")%>
                                            </itemtemplate>
                                                <itemstyle horizontalalign="Center" width="120px" />
                                                <headerstyle horizontalalign="Center" width="120px" />
                                            </asp:TemplateField>
                                            <asp:TemplateField meta:resourcekey="gvProdHierarchy" SortExpression="ProdHierarchy">
                                                <itemtemplate>
                                                <%#Eval("ProdHierarchy")%>
                                            </itemtemplate>
                                                <itemstyle horizontalalign="Center" width="150px" />
                                                <headerstyle horizontalalign="Center" width="150px" />
                                            </asp:TemplateField>
                                            <asp:BoundField DataField="Description" meta:resourcekey="gvDescription" SortExpression="Description" />
                                         <%--   <asp:TemplateField meta:resourcekey="gvMMPP" SortExpression="MMPP_Text">
                                                <itemtemplate>
                                                <%#Eval("MMPP_Text")%>
                                            </itemtemplate>
                                                <itemstyle horizontalalign="Center" width="120px" />
                                                <headerstyle horizontalalign="Center" width="120px" />
                                            </asp:TemplateField>--%>
                                            <asp:TemplateField meta:resourcekey="gvPA" SortExpression="PAllow">
                                                <itemtemplate>
                                                <%#Eval("PAllow")%>%
                                            </itemtemplate>
                                                 <itemstyle horizontalalign="Center" />
                                                 <headerstyle horizontalalign="Center" />
                                            </asp:TemplateField>
                                                       <asp:TemplateField meta:resourcekey="gvListP" SortExpression="ListP">
                                                <itemtemplate>
                                                <%#Eval("ListP")%>
                                            </itemtemplate>
                                                <itemstyle horizontalalign="Center" />
                                                <headerstyle horizontalalign="Center" />
                                            </asp:TemplateField>
                                                       <asp:TemplateField meta:resourcekey="gvSTD" SortExpression="STD">
                                                <itemtemplate>
                                                <%#Eval("STD")%>
                                            </itemtemplate>
                                                <itemstyle horizontalalign="Center" />
                                                <headerstyle horizontalalign="Center" />
                                            </asp:TemplateField>
                                            <asp:TemplateField>
                                                <itemtemplate>
                                                <asp:Button runat="server" ID="btnEdit" CommandName="EditDummyProduct" meta:resourcekey="btnEdit"></asp:Button>   
                                                <asp:Button runat="server" ID="btnDelete" CommandName="DeleteDummyProduct" meta:resourcekey="btnDelete"></asp:Button>     
                                                <ajaxToolkit:ConfirmButtonExtender TargetControlID="btnDelete" ID="cbeDelete" meta:resourcekey="cbeDelete" runat="server">
                                                </ajaxToolkit:ConfirmButtonExtender>
                                            </itemtemplate>
                                                <itemstyle horizontalalign="Center" width="120px" />
                                                <headerstyle horizontalalign="Center" width="120px" />
                                            </asp:TemplateField>
                                        </Columns>
                                    </My:MyGridView>
                                </td>
                            </tr>
                        </table>
                    </fieldset>
                </asp:View>
                <asp:View ID="vwAddDummyProduct" runat="server">
                    <fieldset id="plAddDummyProduct" style="border-color: #4E333B" runat="server">
                        <legend class="white2">
                            <asp:Literal ID="Literal4" runat="server" Text="<%$ Resources:plAddDummyProduct.GroupingText%>" />
                        </legend>
                        <table>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label3" runat="server" meta:resourcekey="lblLevelDescription"></asp:Label>
                                </td>
                                <td align="left">
                                    <asp:Label ID="lblProdLevelDescription" runat="server"></asp:Label>
                                </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label7" runat="server" meta:resourcekey="lblProductHierarchy"></asp:Label>
                                </td>
                                <td align="left">
                                    <asp:TextBox ID="txtProdHierarchy" MaxLength="50" runat="server"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="rfvProdHierarchy" runat="server" ControlToValidate="txtProdHierarchy"
                                        Display="None" ValidationGroup="vDummyProduct" SetFocusOnError="true" meta:resourcekey="rfvProductHierarchy"></asp:RequiredFieldValidator>
                                </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label5" runat="server" meta:resourcekey="lblSapCode"></asp:Label>
                                </td>
                                <td align="left">
                                    <asp:TextBox ID="txtSapCode" MaxLength="8" runat="server"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="rfvSapCode" runat="server" ControlToValidate="txtSapCode"
                                        Display="None" ValidationGroup="vDummyProduct" SetFocusOnError="true" meta:resourcekey="rfvSapCode"
                                        Enabled="false"></asp:RequiredFieldValidator>
                                </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label9" runat="server" meta:resourcekey="lblDescription"></asp:Label>
                                </td>
                                <td align="left">
                                    <asp:TextBox ID="txtProdDescription" MaxLength="50" Width="400px" runat="server"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="rfvProdDescription" runat="server" ControlToValidate="txtProdDescription"
                                        Display="None" ValidationGroup="vDummyProduct" SetFocusOnError="true" meta:resourcekey="rfvDescription"></asp:RequiredFieldValidator>
                                </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label4" runat="server" meta:resourcekey="lblLocalDescription"></asp:Label>
                                </td>
                                <td align="left">
                                    <asp:TextBox ID="txtLocalDescription" MaxLength="50" Width="400px" runat="server"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="rfvLocalDescription" runat="server" ControlToValidate="txtLocalDescription"
                                        Display="None" ValidationGroup="vDummyProduct" SetFocusOnError="true" meta:resourcekey="rfvLocalDescription"></asp:RequiredFieldValidator>
                                </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label6" runat="server" meta:resourcekey="lblMMPP"></asp:Label>
                                </td>
                                <td align="left">
                                    <asp:DropDownList ID="ddlMMPP" runat="server" />
                                    <asp:RequiredFieldValidator InitialValue="" ID="rfvMMPP" runat="server" ControlToValidate="ddlMMPP"
                                        Display="None" ValidationGroup="vDummyProduct" SetFocusOnError="true" meta:resourcekey="rfvMMPP"></asp:RequiredFieldValidator>
                                </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label8" runat="server" meta:resourcekey="lblPAllow"></asp:Label>
                                </td>
                                <td align="left" class="white2">
                                    <asp:TextBox ID="txtPAllow" Columns="3" onkeypress="JHshNumberText()" MaxLength="10"
                                        runat="server"></asp:TextBox>%
                                    <asp:RangeValidator ID="rvPAllow" ErrorMessage="The P.Allowance is over Range(0~100)!!"
                                        Display="None" SetFocusOnError="true" ValidationGroup="vDummyProduct" Type="Integer"
                                        runat="server" ControlToValidate="txtPAllow" MaximumValue="100" MinimumValue="0"></asp:RangeValidator>
                                </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label10" runat="server" meta:resourcekey="lblListP"></asp:Label>
                                </td>
                                <td align="left">
                                    <asp:TextBox ID="txtListP" Columns="3" onkeypress="JHshNumberText()" MaxLength="10"
                                        runat="server"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label11" runat="server" meta:resourcekey="lblSTD"></asp:Label>
                                </td>
                                <td align="left">
                                    <asp:TextBox ID="txtSTD" Columns="3" onkeypress="JHshNumberText()" MaxLength="10"
                                        runat="server"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    <asp:Label ID="Label12" Visible="false" runat="server" meta:resourcekey="lblAutoFill"></asp:Label>
                                </td>
                                <td align="left">
                                    <asp:CheckBox ID="chkAutoFill" Text="Auto Fill" runat="server" />
                                </td>
                            </tr>
                            <tr>
                                <td align="center" colspan="2">
                                    <asp:Button ID="btnSaveDummyProduct" ValidationGroup="vDummyProduct" runat="server"
                                        meta:resourcekey="btnSaveDummyProduct" />
                                    <asp:Button ID="btnCancelDummyProduct" runat="server" meta:resourcekey="btnCancelDummyProduct" />
                                    <asp:ValidationSummary ID="ValidationSummary2" runat="server" ShowMessageBox="True"
                                        ShowSummary="false" ValidationGroup="vDummyProduct" />
                                </td>
                            </tr>
                        </table>
                    </fieldset>
                </asp:View>
                </asp:MultiView> 
<%--            </ContentTemplate>
     </asp:UpdatePanel>--%>
     </div>
 